<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN" 
                    "http://www.w3.org/TR/html4/loose.dtd">

<?php 
session_start();
if(isset($_SESSION['access'])){
$page = ($_SESSION['access'] == 0) ? 'studentmasterpage.php' : 'facultymasterpage.php';
include $page;
}
else{
echo $_SESSION['name'];
echo $_SESSION['access'];
echo "the session isnt working";
}
?>

<html>
<head>
  <script src="http://code.jquery.com/jquery-latest.js"></script>
  <script type="text/javascript" src="http://jzaefferer.github.com/jquery-validation/jquery.validate.js"></script>
<style type="text/css">
* { font-family: Verdana; font-size: 96%; }
label { width: 10em; float: left; }
label.error { float: none; color: red; padding-left: .5em; vertical-align: top; }
p { clear: both; }
.submit { margin-left: 12em; }
em { font-weight: bold; padding-right: 1em; vertical-align: top; }
</style>
  <script>
  $(document).ready(function(){
    $("#commentForm").validate();
  });
  </script>
  
</head>
<body>
  

 <form class="cmxform" id="commentForm" method="post" action="coursecreate.php">
 <fieldset>
   <legend>Create Your Course Schedule</legend>
   <p>
     <label for="coursename">Course Name:</label>
     <em>*</em><input id="coursename" name="coursename" size="25" class="required" minlength="2" />
   </p>
   <p>
     <label for="section">Section Number:</label>
     <em>*</em><input id="section" name="section" size="25" class="required" minlength="2" />
   </p>
   <p>
     <label for="prereq">Prerequisite:</label>
     <em>*</em><input id="prereq" name="prereq" size="25" class="required" minlength="2" />
   </p>
   <p>
     <label for="semester">Semester:</label>
     <em>*</em><input id="semester" name="semester" size="25" class="required" minlength="2" />
   </p>
   <p>
     <label for="location">Location:</label>
     <em>*</em><input id="location" name="location" size="25" class="required" minlength="2" />
   </p>
   <p>
     <label for="capacity">Capacity:</label>
     <em>*</em><input id="capacity" name="capacity" size="25" class="required" minlength="2" />
   </p>
   <p>
     <label for="avail">Availability:</label>
     <em>*</em><input id="avail" name="avail" size="25" class="required" minlength="2" />
   </p>
   <input type="submit" name ="submit" value="Submit" />
 </fieldset>
 </form>
 <?php include 'footer.php'; ?>
</body>
</html>